//------------------------------------------------------------------------------
//------------------------------  config file  ---------------------------------
//------------------------------------------------------------------------------

#ifndef APP_CFG_H_H_
#define APP_CFG_H_H_

#include "mytype.h"

#ifdef __cplusplus
extern "C"
{
#endif

//------------------------------------------------------------------------------
//------------------------------ COMMON CONFIG ---------------------------------
//------------------------------------------------------------------------------
#define VERSION_ID 0x5536

#define SEC_PER_MIN ((ii16)60)
#define MIN_PER_HOUR ((ii16)60)

//------------------------------------------------------------------------------
//------------------------------- GROUP CONFIG ---------------------------------
//------------------------------------------------------------------------------
#define PROG_SEG_MIN 1 // prog par same as t-box
#define PROG_SEG_MAX 24

#define GP_BASE_MAX 3 // group par same as stri
#define GP_LIST_MAX 80

//------------------------------------------------------------------------------
//------------------------------- EEP CONFIG -----------------------------------
//------------------------------------------------------------------------------
#define EEP_EN 0
#define EEP_ENCPTY_EN 0

#define EEP_SYS_PAR_BASE 0
#define EEP_GROUP_PAR_BASE 0x200
#define EEP_PROG_PAR_BASE 0x800

#define EEP_LIC_BASE	0xC00

//------------------------------------------------------------------------------
//--------------------------    SWSPI FLASH     --------------------------------
//------------------------------------------------------------------------------
#define SWNOR_BASE_PAR (32*1024) //32 KB
#define SWNOR_BASE_SIMP_FAT_TAB (1 * 1024 * 1024) // 128KB
#define SWNOR_BASE_LOG_BUFF (4 * 1024 * 1024) //512 KB
#define SWNOR_BASE_MIX_LOG_BUFF (4 * 1024 * 1024 + 512 * 1024) // 1MB


//------------------------------------------------------------------------------
//--------------------------   QPI NOR FLASH    --------------------------------
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
//--------------------------   QPI NAND FLASH   --------------------------------
//------------------------------------------------------------------------------
#define NAND_BASE_BLOCK_LOG 10 //20 block
#define NAND_BASE_BLOCK_MIX_LOG 50 // 20 block
#define NAND_BASE_SIMP_FAT      80   //100 block



//------------------------------------------------------------------------------
//-------------------------------    EOF     -----------------------------------
//------------------------------------------------------------------------------

#ifdef __cplusplus
}
#endif

#endif /* APP_CFG_H_H_ */
